<template>
	<view class="content-list">
		<content-list :dataList="dataList"></content-list>
	</view>
</template>

<script>
	import mixins from "@/utils/mixins.js"
	import contentList from '../../common/contentList.vue'
	export default {
		name: 'schange',
		mixins: [mixins],
		components: {
			contentList,
		},
		props: {
			titleName: {
				type: String,
				default: ''
			},
			dataList: {
				type: Array,
				default: () => {
					return []
				}
			}
		},
		data() {
			return {

			}
		},
		methods: {
			jump(id) {
				uni.navigateTo({
					url: `/pages/engineeringMaintenance/on_site_inspection/components/modifyDisease?id=${id}&name=${this.titleName}`
				})
			},
			setBgColor(str) {
				const greenList = ['高转中', '高转低', '高转无', '中转低', '中转无', '低转无']
				const orangeList = ['低转高', '低转中', '中转高']
				if (str === '无') {
					return 'grey'
				} else if (str === '新增') {
					return 'blue'
				} else if (greenList.includes(str)) {
					return 'green'
				} else if (orangeList.includes(str)) {
					return 'orange'
				} else {
					return ''
				}
			}
		}
	}
</script>

<style lang="scss" scoped>
</style>
